﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace WindowsFormsApplication1
{
    public partial class addRGBform : Form
    {
        public addRGBform()
        {
            InitializeComponent();
        }
        public myRGB TheValue
        {

            get { return new myRGB(Int32.Parse(txbxRed.Text), Int32.Parse(txbxGreen.Text), Int32.Parse(txbxBlue.Text)); }
        }



        private void btAddRGB_Click(object sender, EventArgs e)
        {
            if (txbxRed.Text == "")
            {
                txbxRed.Text = "0";

            }
            if (txbxGreen.Text == "")
            {
                txbxGreen.Text = "0";
            }
            if (txbxBlue.Text == "")
            {
                txbxBlue.Text = "0";
            }
            Close();
        }
    }
}
